home *** CD-ROM | disk | FTP | other *** search
/ PC World 2007 January / PCWorld_2007-01_cd.bin / v cisle / autoit / autoit-v3.2.0.1-setup.exe / Examples / Helpfile / _GUICtrlStatusBarGetTip.au3 < prev    next >
Encoding:
Text File  |  2006-08-01  |  1.1 KB  |  39 lines

  1. opt("MustDeclareVars", 1)
  2.  
  3. #include <GUIConstants.au3>
  4. #Include <GuiStatusBar.au3>
  5.  
  6. Local $gui, $StatusBar1, $msg, $lbl_Info
  7. Local $a_PartsRightEdge[3] = [100, 350, -1]
  8. Local $a_PartsText[3] = ["New Text", "More Text", "Even More Text"]
  9.  
  10. $gui = GUICreate("Status Bar Get Tip Text", 500, -1, -1, -1, $WS_SIZEBOX)
  11.  
  12. $StatusBar1 = _GUICtrlStatusBarCreate ($gui, $a_PartsRightEdge, "", $SBT_TOOLTIPS)
  13.  
  14. _GUICtrlStatusBarSetIcon ($StatusBar1, 1, "shell32.dll", 168)
  15. _GUICtrlStatusBarSetIcon ($StatusBar1, 0, "shell32.dll", 21)
  16. _GUICtrlStatusBarSetIcon ($StatusBar1, 2, "shell32.dll", 24)
  17.  
  18. _GUICtrlStatusBarSetTip ($StatusBar1, 0, "Part 1")
  19. _GUICtrlStatusBarSetTip ($StatusBar1, 1, "This is a Tip for the status bar")
  20. _GUICtrlStatusBarSetTip ($StatusBar1, 2, "Part 3")
  21.  
  22. $lbl_Info = GUICtrlCreateLabel("Tip Text of 2nd Part: " & _GUICtrlStatusBarGetTip ($StatusBar1, 1), 10, 10, 250, 20)
  23.  
  24. GUISetState(@SW_SHOW)
  25.  
  26.  
  27.  
  28. While 1
  29.     $msg = GUIGetMsg()
  30.     Select
  31.         Case $msg = $GUI_EVENT_RESIZED
  32.             _GUICtrlStatusBarResize ($StatusBar1)
  33.         Case $msg = $GUI_EVENT_CLOSE
  34.             ExitLoop
  35.         Case Else
  36.             ;;;;;
  37.     EndSelect
  38.     
  39. WEnd